<template>
  <a-config-provider :locale="locale">
    <router-view />
  </a-config-provider>
</template>

<script setup>
import zhCN from 'ant-design-vue/locale/zh_CN'
import enUs from 'ant-design-vue/locale/en_US'
import useAppStore from '@/store/modules/app'

const appStore = useAppStore()

const locale = computed(() => appStore.locale === 'zhCN' ? zhCN : enUs)
</script>
